<script setup>
import {ref} from 'vue'
const lists = ref([
    {name:'推荐',url:'/home/index/topic-recommend'},
    {name:'交易中心',url:'/home/index/topic-trade'},
    {name:'打听求助',url:'/home/index/topic-help'},
    {name:'恋爱交友',url:'/home/index/topic-love'},
    {name:'校园趣事',url:'/home/index/topic-campus'},
    {name:'兼职招聘',url:'/home/index/topic-recruit'},
])
</script>

<template>
<div class = "content-left">
        <div class = "card">
         <el-menu
         :default-active="$router.parh"
        class="el-menu-demo"
        mode="horizontal" router>
            <el-menu-item :index="v.url" v-for = "v in lists" :key = "v.url ">
            <span>{{v.name}}</span>
            </el-menu-item>
        </el-menu>
        <router-view/>
    </div>
</div>  
</template>
<style scoped>
.content-left{
    width:700px;
    flex-shrink: 0;
    margin-right:10px;
    margin-top: -30px ;
}


</style>